package priv.mill.proxy;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;

public class IteratorMain {

	public static void main(String[] args) {
		List<String> names=new ArrayList<String>();
		
		for (int i = 0; i < 50; i++) {
			names.add(getNameRandom());
		}
		
//		for (String string : names) {
//			System.out.println(string);
//		}
		
		Iterator<String> iterator = names.iterator();
		while(iterator.hasNext()){
			System.out.println(iterator.next());
		}
	}

	private static String getNameRandom() {
		char[] charArray = "赵钱孙里周吴郑王".toCharArray();
		char[] charArray3 = "创建社会主义现代化祖国".toCharArray();
		char[] charArray2 = "春夏秋冬花草树木".toCharArray();
		return String.valueOf(new char[]{
				charArray[(int) (Math.random()*8)],
				charArray3[(int) (Math.random()*charArray3.length)],
				charArray2[(int) (Math.random()*charArray2.length)],
		});
	}
}
